<template>
    <main class="formItem">
        <span class="label">{{ label }}</span>
        <slot></slot>
        {{  errObj.mobile }}
    </main>
</template>

<script>

export default {
    name:'FormItem',
    props:{
        name: String,
        label: {
            type: String,
            default: ''
        },
    },
    inject: ['errObj'],
    mounted(){
        console.log(this.errObj);
    },
    data(){
        return {
        }
    },
}
</script>

<style lang="less">
    .formItem{
        margin-bottom: 24px;

        .label {
            font-weight: 600;
            display: inline-block;
            margin-bottom: 24px;
        }
    }
</style>